package simulation1;

import java.util.Date;
import java.util.Random;
import java.util.Scanner;

public class Start {

	public Car[] car;
	Road road;
	public Random gen;
	Start(int no_of_cars,int no_of_segments){
		
		int i=0;
		
		road = new Road(no_of_segments);
		car = new Car[no_of_cars];
		 gen= new Random();
		
	/*	for(i=0;i<no_of_cars;i++){
			
			car[i]=new Car(i,road,gen.nextInt(2),gen.nextInt(2),Double.parseDouble(Integer.toString(gen.nextInt(16)+10)));
		
		}*/
		
		car[0]=new Car(0,road,0,1,25.0);
		car[1]= new Car(1,road,0,1,25.0);
		car[2]=new Car(2,road,1,0,25.0);
		car[3]=new Car(3,road,1,1,25.0);
		/*car[4]=new Car(4,road,0,1,25.0);
		car[5]=new Car(5,road,0,0,30.0);*/
		
	}
	
	public static void main(String[] args){
		
			
		int no_of_cars ;
		int no_of_segments;
		Scanner in = new Scanner(System.in);
		System.out.println("Enter the value for no.of segments(>=5) : ");
		no_of_segments = in.nextInt();
	       System.out.println("Enter the value for no. of cars(>=2) : ");
	       no_of_cars =in.nextInt();
	       in.close();
		Start st = new Start(no_of_cars,no_of_segments);		
	}
	
}